/**
 * 
 */
package org.acompanhamento.dao;

import java.util.List;

import org.acompanhamento.domain.Status;
import org.acompanhamento.domain.Workflow;
import org.hibernate.Criteria;

import bancosys.tec.persist.dao.BaseDAO;
import bancosys.tec.persist.hibernate.RestrictionsUtils;

/**
 * @author icaro
 *
 */
public class StatusDAO extends BaseDAO<Status>{

	public List<Status> findByWorkflow(Workflow workflow){
		Criteria criteria = this.createCriteria();
		RestrictionsUtils.addRestrictionEq(criteria, "workflow", workflow);
		return this.executeQuery(criteria);
	}

}
